Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for processing messages after MProc drop/reject. #261

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mniemiec
Copy link
Collaborator

We do not attempt to process messages successfuly if there was MProc rule reject or drop.

@vetss
Copy link
Contributor

vetss commented Oct 31, 2017

Hello @mniemiec

I have checked your update but I did not get which issue it tries to fix.

  1. can you please comment more what do you mean "We do not attempt to process messages successfuly if there was MProc rule reject or drop.". Which behaviour do you expect ?

  2. commit "mproc drop correction" makes some refactroing of logging / CDR changing. Can you explain what exactly is changed. I have not found significant changes in behaviour except of code refactoring.

  3. commit "We do not attempt to process messages successfuly if there was MProc rule reject or drop." changes following behavior:

  • before the fix we have: if mproc rules marked a message as rejected / dropped and added extra new messages to send - we reject / drop a message and add send added messages
  • after the fix we will have: if mproc rules marked a message as rejected / dropped and added extra new messages to send - we reject / drop a message and add DO NOT send added messages

Is it a behavior change you want to achieve ? If yes, can you explain WHY do we need such change ?

@ovoo-unif
Copy link
Collaborator

ovoo-unif commented Oct 31, 2017

Hi Sergey,

in case of message rejection by MProc Rule we had NullPointerException because smss:

FastList smss = mProcResult.getMessageList();

was null. The NPE was thrown when it comes to iterate with:

for (FastList.Node n = smss.head(), end = smss.tail(); (n = n.getNext()) != end;) {
...
}

So I suggest first to check if we are rejected/dropped. Then if not we can assume the smss is filled in.

Regards,
adam

@vetss
Copy link
Contributor

vetss commented Nov 6, 2017

Hello Adam, @ovoo-unif

in case of message rejection by MProc Rule we had NullPointerException because smss:

ok, this is a good point and I prepared a separate commit to avoid of this case. Thanks for bug reporting. This is a refecrense to commit :
7adea89

Can we discuss your PR and my questions (for your PR):

can you please comment more what do you mean "We do not attempt to process messages successfuly if there was MProc rule reject or drop.". Which behaviour do you expect ?

  1. can you please comment more what do you mean "We do not attempt to process messages successfuly if there was MProc rule reject or drop.". Which behaviour do you expect ?

  2. commit "mproc drop correction" makes some refactroing of logging / CDR changing. Can you explain what exactly is changed. I have not found significant changes in behaviour except of code refactoring.

  3. commit "We do not attempt to process messages successfuly if there was MProc rule reject or drop." changes following behavior:

  • before the fix we have: if mproc rules marked a message as rejected / dropped and added extra new messages to send - we reject / drop a message and add send added messages
  • after the fix we will have: if mproc rules marked a message as rejected / dropped and added extra new messages to send - we reject / drop a message and add DO NOT send added messages

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants